var plan = require ('./RendezVous.js');

//Définition donnée de test
var planningTest = new plan.Semaine();
var dayToAdd = null;
var	rdv = null;

for(var i=0; i<7; i++){
	dayToAdd = new plan.PlanningJour();
	dayToAdd.jour = i;
	for(var j=0; j<48; j++){
		rdv = new plan.RendezVous();
		rdv.dateIntervention = "coucou" + i;
		rdv.heureIntervention = "rien";
		rdv.duree = 0.5;
		rdv.responsable = "user";
		rdv.lieu = "ici ou " + j;
		dayToAdd.listeRendezVous[j] = rdv;
	}
	planningTest.listePlanning[i] = dayToAdd;
}

console.log(planningTest.countDurationInterventions());
planningTest.toCSV('export/test_export_Ical_to_CSV.csv');
